# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=libicu64
_pkgname=icu
pkgver=64.2
pkgrel=1
pkgdesc='International Components for Unicode library.'
arch=('x86_64' 'aarch64')
url='http://www.icu-project.org/'
license=('custom:ICU')
depends=('gcc-libs')
source=("http://download.icu-project.org/files/icu4c/$pkgver/icu4c-${pkgver//./_}-src.tgz")
sha512sums=('5ecb4c230ba45918747a1cf9aef86f555aa07d5b29b1d07ab674e8013f46dfb907a0e9d6945db41155f9dc3012fd94e1152ffc19f61a68b6dfcbabdcb8ae9d78')

build() {
  cd "$_pkgname/source"

  ./configure --prefix=/usr --sysconfdir=/etc --mandir=/usr/share/man \
    --libdir=/usr/lib

  make
}

package() {
  cd "$_pkgname/source"

  install -dm 755 "$pkgdir/usr/lib"

  cp -a lib/libicu*64* "$pkgdir/usr/lib"

  install -Dm 644 "$srcdir/$_pkgname/license.html" \
    "$pkgdir/usr/share/licenses/$pkgname/license.html"
}

